<%--
  @author Supun Nimesh Karunathilaka
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="s" uri="/struts-tags" %>
<script type="text/javascript">
    $(document).ready(function() {
        var pls_select_item = "<br>" + document.getElementById("pls_select_item").value;
        $("#lands-by-alienation-type").validate({
            rules:{
                alienation_type:{
                    selectBox:"default"
                }
            },
            messages:{
                alienation_type:{
                    selectBox:pls_select_item
                }
            }
        });
    });
</script>
<div id="land-registration-module-home-title" class="module-home-title">
    <s:a href="searchModule.do"><img src="${pageContext.request.contextPath}/images/search.png"
                                     alt="Land Alienation"><span><s:label
            value="%{getText('search.label')}"/></span></s:a>
    <span class="module-title-breaker"> > </span>
    <s:a href="initViewAssociationList.do"><img
            src="${pageContext.request.contextPath}/images/searchLand.png"><span><s:label
            value="%{getText('search_lands_by_alienation.label')}"/></span></s:a>
    <div id="back-button" align="right">
            <s:form><s:submit value="%{getText('back_btn.label')}" action="searchModule"/></s:form>
    </div>
</div>

<div class="page-title">
    <h2><s:label value="%{getText('search_lands_by_alienation.label')}"/></h2>
</div>
<div id="search-lands-form-outer">
    <s:form id="lands-by-alienation-type" name="lands-by-alienation-type">
        <table class="width-100">
            <tr>
                <td><s:label value="%{getText('alienation_method.label')}"/></td>
                <td><s:select list="alienationTypeList" id="alienation_type" name="alienationType"
                              headerValue="%{getText('select.label')}" headerKey="0"/></td>
                <td><s:submit value="%{getText('search.label')}" action="viewLandAssociation"/></td>
            </tr>
        </table>
    </s:form>
</div>

<s:hidden id="pls_select_item" value="%{getText('pls_select_alienation_method.label')}"/>